package org.ogv.collision;

import com.badlogic.gdx.graphics.Texture;
import com.badlogic.gdx.graphics.g2d.Sprite;
import com.badlogic.gdx.graphics.g2d.SpriteBatch;
import com.badlogic.gdx.math.Rectangle;

public class BoundingRect extends Rectangle {

	private static Sprite _debugTex;
	public void draw(SpriteBatch sb, float offsetX, float offsetY) {
		if(_debugTex == null) getDebugTex();
		_debugTex.setOrigin(0, 0);
		_debugTex.setScale(width/_debugTex.getTexture().getWidth(), height/_debugTex.getTexture().getHeight());
		_debugTex.setPosition(x + offsetX, y + offsetY);
		_debugTex.draw(sb);
	}
	
	private void getDebugTex() {
		_debugTex = new Sprite(new Texture("data/rect64.png"));
	}
}
